import {createApp} from 'vue';
import ElementPlus from 'element-plus';
import 'element-plus/dist/index.css';
import * as ElementPlusIconsVue from '@element-plus/icons-vue';
import {install} from '@icon-park/vue-next/es/all';
import globalComponents from '@/components';
import router from './router';
import store from './store';
import i18n from './locale';
import directive from './directive';
import App from './App.vue';
import '@icon-park/vue-next/styles/index.css';
import '@/assets/style/global.less';
import '@/api/interceptor';

const app = createApp(App);

install(app, "i")
app.use(ElementPlus);

app.use(router);
app.use(store);
app.use(i18n);
app.use(globalComponents);
app.use(directive);

for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
    app.component(key, component)
}

app.mount('#app');
